package com.baizhi.app.appservice.impl;
import com.baizhi.app.appservice.CmfzAlbumAppService;
import com.baizhi.entity.CmfzAlbum;
import com.baizhi.mapper.CmfzAlbumMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
@Service
public class CmfzAlbumAppServiceImpl implements CmfzAlbumAppService {
    @Autowired
    private CmfzAlbumMapper cmfzAlbumMapper;
    @Override
    public List<CmfzAlbum> selectAnyAlbum(String type) {
        if (type.equals("new")){
            List<CmfzAlbum> cmfzAlbums = cmfzAlbumMapper.selectAnyAlbum();
            return cmfzAlbums;
        }else {
            List<CmfzAlbum> cmfzAlbums = cmfzAlbumMapper.selectList(null);
            return cmfzAlbums;
        }
    }
}
